package com.brillilab.service.core.kit;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

import com.brillilab.domain.po.kit.KitSpec;

/**
 * kit规格Service
 * 
 * @author lj
 *
 */
public interface IKitSpecService {

	KitSpec insert(KitSpec entity);
	
	boolean deleteById(Long id);

	boolean updateById(KitSpec entity);

	KitSpec selectById(Long id);
	
	/**
	 * 获取kit的规格组
	 * @param kitId
	 * @return
	 */
	List<KitSpec> selectSpecGroup(Long kitId);
	/**
	 * 获取kit的规格组
	 * @param kitIds
	 * @return
	 */
	Map<Long, List<KitSpec>> selectSpecGroup(List<Long> kitIds);
	
	/**
	 * 获取kit的规格
	 * @param kitId
	 * @param kitSize
	 * @return
	 */
	List<KitSpec> selectList(Long kitId,BigDecimal kitSize);
	/**
	 * 获取kit的规格
	 * @param kitId
	 * @param reagentId
	 * @return
	 */
	List<KitSpec> selectSpecList(Long kitId,Long reagentId);
	
	/**
	 * @Description: getKitSpecListBySpecId
	 * @Params: [specId]
	 * @return java.util.List<com.brillilab.domain.po.kit.KitSpec>
	 * @author wuzhiyu
	 * @date 2018/11/19 11:20
	 */
	List<KitSpec> getKitSpecListBySpecId(Long specId);
	
	/**
	 * 组装规格名称
	 * @param specList
	 * @param type  0-Kit规格，1-成分规格
	 * @return
	 */
	String getSpecName(List<KitSpec> specList, Integer type);
	/**
	 * 批量插入规格
	 * @param entity
	 */
	void insertBatch(List<KitSpec> specList);

	List<KitSpec> selectListByIds(Long kitId, Long[] spectIds);

	/**
	 * kit的所有kitSpec
	 * @param kitId
	 * @return
	 */
    List<KitSpec> selectList(Long kitId);

	List<KitSpec> selectList(List<Long> kitIds);
}
